<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  

  
  <title>一、学习怎么写博客吧！ | Hexo</title>
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <meta name="description" content="安装博客一、安装 cnpm i  -g hexo-cli 初始化项目 hexo init  运行 hexo s  二、 hexo常用命令 hexo new “标题” hexo clean 清除缓存，效果不一致时使用 hexo g  用md变静态页面  三、使用typora四、部署博客 新建仓库 git插件 hexo-deployer 配置文件  _config.yml hexo d 部署项目，然后">
<meta property="og:type" content="article">
<meta property="og:title" content="一、学习怎么写博客吧！">
<meta property="og:url" content="https://gitee.com/web-zhangpei/2021/12/21/%E7%AC%AC%E4%B8%80%E7%AF%87%E5%8D%9A%E5%AE%A2/index.html">
<meta property="og:site_name" content="Hexo">
<meta property="og:description" content="安装博客一、安装 cnpm i  -g hexo-cli 初始化项目 hexo init  运行 hexo s  二、 hexo常用命令 hexo new “标题” hexo clean 清除缓存，效果不一致时使用 hexo g  用md变静态页面  三、使用typora四、部署博客 新建仓库 git插件 hexo-deployer 配置文件  _config.yml hexo d 部署项目，然后">
<meta property="og:locale" content="en_US">
<meta property="article:published_time" content="2021-12-21T03:30:14.698Z">
<meta property="article:modified_time" content="2021-12-21T03:55:11.233Z">
<meta property="article:author" content="John Doe">
<meta name="twitter:card" content="summary">
  
    <link rel="alternate" href="/web-zhangpei/atom.xml" title="Hexo" type="application/atom+xml">
  
  
    <link rel="icon" href="/favicon.png">
  
  
    <link href="//fonts.googleapis.com/css?family=Source+Code+Pro" rel="stylesheet" type="text/css">
  
  
<link rel="stylesheet" href="/web-zhangpei/css/style.css">

<meta name="generator" content="Hexo 5.4.0"></head>

<body>
  <div id="container">
    <div id="wrap">
      <header id="header">
  <div id="banner"></div>
  <div id="header-outer" class="outer">
    <div id="header-title" class="inner">
      <h1 id="logo-wrap">
        <a href="/web-zhangpei/" id="logo">Hexo</a>
      </h1>
      
    </div>
    <div id="header-inner" class="inner">
      <nav id="main-nav">
        <a id="main-nav-toggle" class="nav-icon"></a>
        
          <a class="main-nav-link" href="/web-zhangpei/">Home</a>
        
          <a class="main-nav-link" href="/web-zhangpei/archives">Archives</a>
        
      </nav>
      <nav id="sub-nav">
        
          <a id="nav-rss-link" class="nav-icon" href="/web-zhangpei/atom.xml" title="RSS Feed"></a>
        
        <a id="nav-search-btn" class="nav-icon" title="Search"></a>
      </nav>
      <div id="search-form-wrap">
        <form action="//google.com/search" method="get" accept-charset="UTF-8" class="search-form"><input type="search" name="q" class="search-form-input" placeholder="Search"><button type="submit" class="search-form-submit">&#xF002;</button><input type="hidden" name="sitesearch" value="https://gitee.com/web-zhangpei"></form>
      </div>
    </div>
  </div>
</header>
      <div class="outer">
        <section id="main"><article id="post-第一篇博客" class="article article-type-post" itemscope itemprop="blogPost">
  <div class="article-meta">
    <a href="/web-zhangpei/2021/12/21/%E7%AC%AC%E4%B8%80%E7%AF%87%E5%8D%9A%E5%AE%A2/" class="article-date">
  <time datetime="2021-12-21T03:30:14.698Z" itemprop="datePublished">2021-12-21</time>
</a>
    
  </div>
  <div class="article-inner">
    
    
      <header class="article-header">
        
  
    <h1 class="article-title" itemprop="name">
      一、学习怎么写博客吧！
    </h1>
  

      </header>
    
    <div class="article-entry" itemprop="articleBody">
      
        <h2 id="安装博客"><a href="#安装博客" class="headerlink" title="安装博客"></a>安装博客</h2><h3 id="一、安装"><a href="#一、安装" class="headerlink" title="一、安装"></a>一、安装</h3><ol>
<li>cnpm i  -g hexo-cli</li>
<li>初始化项目 hexo init </li>
<li>运行 hexo s</li>
</ol>
<h3 id="二、-hexo常用命令"><a href="#二、-hexo常用命令" class="headerlink" title="二、 hexo常用命令"></a>二、 hexo常用命令</h3><ol>
<li>hexo new “标题”</li>
<li>hexo clean 清除缓存，效果不一致时使用</li>
<li>hexo g  用md变静态页面</li>
</ol>
<h3 id="三、使用typora"><a href="#三、使用typora" class="headerlink" title="三、使用typora"></a>三、使用typora</h3><h3 id="四、部署博客"><a href="#四、部署博客" class="headerlink" title="四、部署博客"></a>四、部署博客</h3><ol>
<li>新建仓库</li>
<li>git插件 hexo-deployer</li>
<li>配置文件  _config.yml</li>
<li>hexo d 部署项目，然后更新gitee pages</li>
</ol>
<h3 id="五、插入图片问题"><a href="#五、插入图片问题" class="headerlink" title="五、插入图片问题"></a>五、插入图片问题</h3><ol>
<li>使用图床</li>
</ol>

      
    </div>
    <footer class="article-footer">
      <a data-url="https://gitee.com/web-zhangpei/2021/12/21/%E7%AC%AC%E4%B8%80%E7%AF%87%E5%8D%9A%E5%AE%A2/" data-id="ckxfjz64l0000hgue5jvidq4f" class="article-share-link">Share</a>
      
      
    </footer>
  </div>
  
    
<nav id="article-nav">
  
  
    <a href="/web-zhangpei/2021/12/21/hello-world/" id="article-nav-older" class="article-nav-link-wrap">
      <strong class="article-nav-caption">Older</strong>
      <div class="article-nav-title">Hello World</div>
    </a>
  
</nav>

  
</article>

</section>
        
          <aside id="sidebar">
  
    

  
    

  
    
  
    
  <div class="widget-wrap">
    <h3 class="widget-title">Archives</h3>
    <div class="widget">
      <ul class="archive-list"><li class="archive-list-item"><a class="archive-list-link" href="/web-zhangpei/archives/2021/12/">December 2021</a></li></ul>
    </div>
  </div>


  
    
  <div class="widget-wrap">
    <h3 class="widget-title">Recent Posts</h3>
    <div class="widget">
      <ul>
        
          <li>
            <a href="/web-zhangpei/2021/12/21/%E7%AC%AC%E4%B8%80%E7%AF%87%E5%8D%9A%E5%AE%A2/">一、学习怎么写博客吧！</a>
          </li>
        
          <li>
            <a href="/web-zhangpei/2021/12/21/hello-world/">Hello World</a>
          </li>
        
      </ul>
    </div>
  </div>

  
</aside>
        
      </div>
      <footer id="footer">
  
  <div class="outer">
    <div id="footer-info" class="inner">
      &copy; 2021 John Doe<br>
      Powered by <a href="http://hexo.io/" target="_blank">Hexo</a>
    </div>
  </div>
</footer>
    </div>
    <nav id="mobile-nav">
  
    <a href="/web-zhangpei/" class="mobile-nav-link">Home</a>
  
    <a href="/web-zhangpei/archives" class="mobile-nav-link">Archives</a>
  
</nav>
    

<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script>


  
<link rel="stylesheet" href="/web-zhangpei/fancybox/jquery.fancybox.css">

  
<script src="/web-zhangpei/fancybox/jquery.fancybox.pack.js"></script>




<script src="/web-zhangpei/js/script.js"></script>




  </div>
</body>
</html>